import cv2
import time
img = cv2.imread("../01_start/dog.jpg", cv2.IMREAD_UNCHANGED)

blue = img.item(20, 100, 0) 
img.itemset((20, 20, 0),255)           
# print(img.shape)
# cv2.imshow("srhe", img)
# k = cv2.waitKey(0)
# if k == 27:
#     # cv2.destroyAllWindows() #删除所有窗口

#     cv2.destroyWindow("srhe") #删除指定窗口
# img[20:80, 20:40,:] = 255
# cv2.imshow("srhe", img)
# k = cv2.waitKey(0)
# blue = img[:, :, 0]
# cv2.imshow("srhe1", blue)
# cv2.waitKey(0)
# green = img[:, :, 1]
# cv2.imshow("srhe2", green)
# print(green.shape)
# cv2.waitKey(0)
# red = img[:, :, 1]
# cv2.imshow("srhe3", red)
# cv2.waitKey(0)